load("@io_bazel_rules_go//go:def.bzl", "go_test")

go_test(
    name = "txntest_test",
    timeout = "moderate",
    srcs = [
        "isolation_test.go",
        "main_test.go",
        "replica_read_test.go",
        "stale_read_test.go",
        "txn_state_test.go",
        "txn_test.go",
    ],
    flaky = True,
    race = "on",
    shard_count = 50,
    deps = [
        "//pkg/config",
        "//pkg/config/kerneltype",
        "//pkg/ddl/placement",
        "//pkg/errno",
        "//pkg/expression",
        "//pkg/kv",
        "//pkg/parser",
        "//pkg/session",
        "//pkg/session/txninfo",
        "//pkg/sessiontxn",
        "//pkg/sessiontxn/staleread",
        "//pkg/store/driver",
        "//pkg/testkit",
        "//pkg/testkit/testfailpoint",
        "//pkg/types",
        "//pkg/util",
        "//pkg/util/sqlexec",
        "//tests/realtikvtest",
        "@com_github_docker_go_units//:go-units",
        "@com_github_pingcap_errors//:errors",
        "@com_github_pingcap_failpoint//:failpoint",
        "@com_github_pingcap_kvproto//pkg/coprocessor",
        "@com_github_pingcap_kvproto//pkg/errorpb",
        "@com_github_pingcap_kvproto//pkg/kvrpcpb",
        "@com_github_stretchr_testify//require",
        "@com_github_tikv_client_go_v2//oracle",
        "@com_github_tikv_client_go_v2//tikvrpc",
        "@com_github_tikv_client_go_v2//tikvrpc/interceptor",
        "@io_opencensus_go//stats/view",
    ],
)
